<section id="comments" class="comments-area">
    <% if post.the_comments.count > 0 %>
        <h2 class="comments-title"><%= post.the_comments.count %> <%= ct('comments', default: 'Comments')%> "<span><%= post.the_title %></span>"</h2>
        <section class="comment-list">
            <%= render partial: "partials/comments_list", locals: { comments: post.the_comments, children: "" } %>
        </section>
    <% end %>
    <div id="respond" class="comment-respond">
        <% if signin? %>
            <h3 id="reply-title" class="comment-reply-title"><%= ct('comment_new', default: 'New Comment')%></h3>
            <%= form_for post, url:{action: :save_comment, post_id: post.id}, html: {method: "post", class: "comment-form"} do |f|%>
                <input type="hidden" name="post_comment[post_id]" value="<%= post.id %>">
                <input type="hidden" name="slug" value="<%= post.slug %>">
                <div class="mb-20">
                    <textarea id="textarea_comments" name="post_comment[content]" class="form-control counted" placeholder="<%= ct('comment', default: 'Enter youe comment here')%>"></textarea>
                </div>
                <div class="mb-20">
                    <button type="submit" class="btn btn-info pull-right"><%= ct('comment', default: 'Comment')%></button>
                </div>
            <% end %>
        <% else %>
            <div class="panel-login-comment"><%= ct('comment_msg', default: 'You need to be logged in')%>  <a class="link-login-comment" href="<%= zerocms_admin_path %>"><%= ct('login', default: 'Login')%></a></div>
        <% end %>
    </div>
</section>